<?php

use think\migration\Migrator;

class AlterMobileOrderHistory extends Migrator
{
    public function up()
    {
        $this->table('mobile_order_history')
            ->addColumn('supplier_price', 'integer', ['default' => 0, 'comment' => '交付给供应商的价格'])
            ->addColumn('platform_profit', 'integer', ['default' => 0, 'comment' => '平台利润'])
            ->save();
    }

    public function down()
    {
        $this->table('mobile_order_history')
            ->removeColumn('supplier_price')
            ->removeColumn('platform_profit');
    }
}
